package com.register.controller;

import com.register.pojo.Department;
import com.register.service.DepartmentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import java.util.List;


@RestController("departmentController")
public class DepartmentController {
    @Autowired
    private DepartmentService departmentService;
    @RequestMapping("/a")
    public  List<Department> getDepartment(){
        List<Department> list = departmentService.getDepartment();
        return list;
    }
}
